﻿/// <reference path="_namespace.js" />

/*****************************************************************************
Ajax library class definition. Kevin Robinson 2008.
Class: ajax.xna.Component
/*****************************************************************************/

ajax.lang.addNamespace("ajax.xna");

ajax.xna.DrawableGameComponent = function(game)
{
    ajax.xna.DrawableGameComponent.superConstructor.call(this, game);
    this.getEvent(this.getWindow(), "onVisibleChanged");
}
ajax.lang.extend("ajax.xna.DrawableGameComponent", "ajax.xna.GameComponent");
if ($getDesignMode())
    ajax.xna.DrawableGameComponent.prototype = ajax.xna.GameComponent.prototype;

// Statics
ajax.xna.DrawableGameComponent.cast = function(obj)
{///<returns type="ajax.xna.DrawableGameComponent"/>
}

// Public properties
ajax.xna.DrawableGameComponent.prototype._visible = true;
ajax.xna.DrawableGameComponent.prototype.getVisible = function(){ return this._visible; }
ajax.xna.DrawableGameComponent.prototype.setVisible = function(value)
{
    this._visible = value;
    this.onVisibleChanged.call(this);
}

// Public Methods
ajax.xna.DrawableGameComponent.prototype.getGraphicsDevice = function()
{///<returns type="ajax.drawing.Device3D"/>
    return this.getGame().graphicsDevice;
}
ajax.xna.DrawableGameComponent.prototype.draw = function(gameTime)
{///<param name="gameTime" type="ajax.drawing.Timer"/>
}
